//package com.chixing.mapper;
//
//import com.mysql.cj.jdbc.MysqlDataSource;
//import org.apache.mahout.cf.taste.impl.model.jdbc.MySQLJDBCDataModel;
//import org.apache.mahout.cf.taste.model.DataModel;
//import org.apache.mahout.cf.taste.model.JDBCDataModel;
//import org.springframework.context.annotation.Bean;
//import org.springframework.stereotype.Component;
//
//@Component
//public class DataConfig {
//    @Bean
//    public DataModel getMySQlDataModel(){
//        MysqlDataSource dataSource = new MysqlDataSource();
//        dataSource.setServerName("sh-cynosdbmysql-grp-hbzy86n2.sql.tencentcdb.com");
//        dataSource.setUser("root");
//        dataSource.setPassword("Zyx123456");
//        dataSource.setDatabaseName("zyx");
//        dataSource.setPort(20699);
//
//        JDBCDataModel dataModel = new MySQLJDBCDataModel(dataSource,"sights_pianhao","cust_id","travel_sights_id","pianhao_value","pianhao_time");
//        return  dataModel;
//    }
//}
